<template>
	<view>
		<view class="floor" v-for="(item,index) in floor" :key="index">
			<view class="title">
				<image :src="item.floor_title.image_src" mode="" style="width: 100%; height: 100rpx;"></image>
			</view>
			<view class="con">
				<view class="left">
					<image :src="item.product_list[0].image_src" mode="" class="left_img"></image>
				</view>
				<view class="right">
					<view class="right_list" v-for="(it,ind) in item.product_list" :key="ind" v-show="ind!=0">
						<image :src="it.image_src" mode="" class="right_img"></image>
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		name:"floor",
		data() {
			return {
				floor:[]
			};
		},
		created() {
			this.getFloor()
		},
		methods:{
			async getFloor(){
				let {data:res} = await uni.$http.get('/api/public/v1/home/floordata')
				console.log(res,'floor')
				this.floor = res.message
			}
		}
	}
</script>

<style lang="scss">
.floor{
	width: 750rpx;
	.con{
		width: 100%;
		display: flex;
		.left{
			flex: 1;
			.left_img{
				width: 250rpx;
			}
		}
		.right{
			flex: 2;
			display: flex;
			flex-wrap: wrap;
			.right_img{
				width: 250rpx;
				height: 233rpx;
			}
		}
	}
}
</style>
